home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
3D Game Programming All in One
/
3D Game Programming All in One Disc.iso
/
3D2E
/
demo
/
server
/
scripts
/
markers.cs
< prev
next >
Wrap
Text File
|
2005-11-23
|
1KB
|
38 lines
//-----------------------------------------------------------------------------
// Torque Game Engine
// Copyright (C) GarageGames.com, Inc.
//-----------------------------------------------------------------------------
datablock MissionMarkerData(WayPointMarker)
{
category = "Misc";
shapeFile = "~/data/shapes/markers/octahedron.dts";
};
datablock MissionMarkerData(SpawnSphereMarker)
{
category = "Misc";
shapeFile = "~/data/shapes/markers/octahedron.dts";
};
//------------------------------------------------------------------------------
// - serveral marker types may share MissionMarker datablock type
function MissionMarkerData::create(%block)
{
switch$(%block)
{
case "WayPointMarker":
%obj = new WayPoint() {
dataBlock = %block;
};
return(%obj);
case "SpawnSphereMarker":
%obj = new SpawnSphere() {
datablock = %block;
};
return(%obj);
}
return(-1);
}